<extend name="Public/common"/>
<block name="othercss">
</block>
<block name="body">
<div class="mian" style="background-color: #f4f4f4">
    <div class="help">
        <div class="box">
            <div class="loc"><i class="icon iconloc"></i>您现在在这里：<a href="{:urlrotue('/')}">白宝库</a> > <a href="{:urlrotue('Member/index')}">个人中心</a> > <span class="on">账号信息</span>
            </div>
            <div class="clearfix help_list">
                <div class="right">
                    <div class="href-a">
                        <a href="{:urlrotue('Member/edit')}" class="on">基本资料</a>
                        <a href="{:urlrotue('Member/headpic')}">头像照片</a>
                    </div>
                    <h2 class="title">账户信息</h2>
                    <div class="zhxx2sum">
                        <form name="frm" id="frm" method="post">
                        <div class="top">手机号：<span>{$member['phone']==''?'未设置':$member['phone']}</span></div>
                        <ul class="zhxx-ul">
                            <li class="clearfix">
                                <div class="zhxx22"><input type="text"  name="nickname" id="nickname" value="{$member.nickname}"  class="i1"/></div>
                                <div class="zhxx21"><span class="red">*</span> 昵称：</div>
                            </li>
                            <li class="clearfix">
                                <div class="zhxx22"><input type="text" name="realname" id="realname" value="{$memberinfo.realname}" class="i2"/></div>
                                <div class="zhxx21">&nbsp;&nbsp;真实姓名：</div>
                            </li>
                            <li class="clearfix">
                                <div class="zhxx22"><div class="label"><div class="rd <if condition="$memberinfo.sex eq '男'">on</if>"> </div>男 <div class="rd <if condition="$memberinfo.sex eq '女'">on</if>"></div>女
                                <input type="hidden" name="sex" id="sex" value="{$memberinfo.sex}" />
                                </div></div>
                                <div class="zhxx21"><span class="red">*</span> 性别：</div>
                            </li>
                            <li class="clearfix">
                                <div class="zhxx22">
                                <select name="year" id="year" class="select1">
                                                <option value="">选择年</option>
                                                <for start="1899" end="2015">
                                                    <option value="{$i}">{$i}年</option>
                                                </for>
                                            </select>
                                            <select name="month" id="month" class="select1">
                                                <option value="">选择月</option>
                                                <option value="01">1月</option>
                                                <option value="02">2月</option>
                                                <option value="03">3月</option>
                                                <option value="04">4月</option>
                                                <option value="05">5月</option>
                                                <option value="06">6月</option>
                                                <option value="07">7月</option>
                                                <option value="08">8月</option>
                                                <option value="09">9月</option>
                                                <option value="10">10月</option>
                                                <option value="11">11月</option>
                                                <option value="12">12月</option>
                                            </select>
                                            <select name="day" id="day" class="select1">
                                                <option value="">选择日</option>
                                                <for start="1" end="10">
                                                    <option value="0{$i}">{$i}日</option>
                                                </for>
                                                <for start="10" end="32">
                                                    <option value="{$i}">{$i}日</option>
                                                </for>
                                            </select>
                        &nbsp;&nbsp;&nbsp;<span style="color: #aaaaaa">填生日有惊喜哦~</span>
                                </div>
                                <div class="zhxx21">&nbsp;&nbsp;生日：</div>
                            </li>
                            <li class="clearfix">
                                <div class="zhxx22">
                               <select name="province" id="province" class="select1">
                            <option value="">选择省份</option>
                                        <foreach name="province" item="prov">
                                            <option value="{$prov.province}">{$prov.province}</option>
                                        </foreach>
                            </select>
                      <span id="span_city"></span>
                                <span id="span_area"></span>
                                <input type="hidden" id="hid_province" name="hid_province" value="{$memberinfo.province}" />
                                <input type="hidden" id="hid_city" name="hid_city" value="{$memberinfo.city}" />
                                <input type="hidden" id="hid_area" name="hid_area" value="{$memberinfo.area}" />&nbsp;&nbsp;&nbsp;
                                    <input type="text" name="address" id="address" value="{$memberinfo.address}" class="i2"/>
                                </div>
                                <div class="zhxx21">&nbsp;&nbsp;所在地区：</div>
                            </li>
                   
                            <li class="clearfix">
                                <div class="zhxx22"><input  type="button" onclick="save()"  class="sub" value="保存"/></div>
                                <div class="zhxx21"></div>
                            </li>
                        </ul>
                        </form>
                        
                    </div>
                </div>
                
                        <include file="Member:left_menu"/>
            </div>
        </div>
    </div>
</div>
</block>
<block name="otherjs">
    <script type="text/javascript">
	$(function(){
	   	$('.zhxx22 .rd').on('click',function(){
		   var index= $(this).index();
		   $(this).addClass('on').siblings().removeClass('on');
		   if(index==0){
		    $('#sex').val('男');
		   }else{
		      $('#sex').val('女');
		   }
		   
	    })
	 })
	</script>
    <input type="hidden"  id="url_member_edit" value="{:U('Member/edit')}" />
    <script type="text/javascript">
            $("#month").val("{$memberinfo.month}");
            $("#year").val("{$memberinfo.year}");
            $("#day").val("{$memberinfo.day}");
            var url_city_sel = "{:U('Address/city_sel')}?";//根据省份获取城市列表
            var url_area_sel = "{:U('Address/area_sel')}?";//根据城市获取地区列表
            var url_get_zip = "{:U('Address/get_zip')}?";//根据地区获取邮政编码
            var url_member_edit = "{:U('Member/edit')}";//提交保存地址
             var url_member_change_pasword = "{:U('Member/change_password')}"; //修改密码提交地址
        </script>
        <script src="{$theme_path}/js/member_edit.js"></script>
        <script src="{$theme_path}/js/member_change_password.js"></script>
</block>
